<!DOCTYPE html>
<html>
<head>
  <title>Popcorn WebPage Plug-in Demo</title>

  <script src="../../popcorn.js"></script>
  <script src="popcorn.webpage.js"></script>
  <script>
    document.addEventListener( "DOMContentLoaded", function() {
      var p = Popcorn( "#video" )
      .volume( 0 )
      .play()
      .webpage({
        id: "webpages-a",
        start: 0,
        end: 5,
        src: "//webmademovies.org/",
        target: "webpagediv"
      })
      .webpage({
        id: "webpages-b",
        start: 0,
        end: 10,
        src: "http://zenit.senecac.on.ca/wiki/index.php/Processing.js",
        target: "webpagediv2"
      });

    }, false);

  </script>
</head>
<body>
  <h1 id="qunit-header">Popcorn WebPage Plug-in Demo</h1>
  <p> A Webpage displaying webmademovies.org will appear at 0 seconds and disappear at 5 seconds.</p>
  <p> A Webpage displaying zenit Processing.js wiki will appear at 0 seconds and disappear at 15 seconds.</p>
  <div>
    <video id="video"
      controls 
      width="250px"
      poster="../../test/poster.png">

      <source id="mp4"
        src="../../test/trailer.mp4"
        type='video/mp4; codecs="avc1, mp4a"'>

      <source id="ogv"
        src="../../test/trailer.ogv"
        type='video/ogg; codecs="theora, vorbis"'>

      <p>Your user agent does not support the HTML5 Video element.</p>

    </video>
  </div>
  <div id="webpagediv" width="50%" height="50%">
  <div id="webpagediv2">
  </div>
</body>
</html>
